#!/bin/bash
TPath=$(cd $(dirname $0); pwd)/src
SPath=/root/publish
FileName='WH.WebApi.service'
sed -i "s?$SPath?$TPath?g" "$FileName"
ServerPath='/etc/systemd/system'
cp $FileName $ServerPath/$FileName
echo 'copy success'
./start.sh
echo 'WH.WebApi server install success'